﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Umbraco.Framework;
using Umbraco.Framework.Persistence.Model.Attribution.MetaData;
using Umbraco.Framework.Persistence.Model.Constants.SerializationTypes;

namespace WebGarden.Hive.Providers.Products.Schema.Model.AttributeTypes
{
	/// <summary>
	/// This class has been copied directly from the Wordpress provider (just changed the namespace).
	/// These standard Umbraco attribute types may eventually be part of Hive
	/// </summary>
    public class TextStringAttributeType : AttributeType
    {
        public const string AliasValue = "wp-text-string";

        public TextStringAttributeType()
            : base(
            AliasValue,
            AliasValue,
            "This type represents internal system text",
            new StringSerializationType())
        {
            Id = new HiveId(AliasValue.EncodeAsGuid());
            RenderTypeProvider = "3F5ED845-7018-4BDE-AB4E-C7106EE0992D";
            RenderTypeProviderConfig = @"
<preValues>
    <preValue name='Mode'><![CDATA[SingleLine]]></preValue>
</preValues>";
        }
    }
}
